home *** CD-ROM | disk | FTP | other *** search
/ System Booster / System Booster.iso / Directorytools / Ro / Install / RO-Install < prev    next >
Text File  |  1996-09-26  |  7KB  |  389 lines

  1. ; $VER: RO-Install 1.22 (30.3.96)
  2. ; Original RO Installer script by Juergen Schubert <juergen@desert.sub.org>
  3. ; Rewritten by Oliver Rummeyer, inspired by MagicCX-Install ©1994 Kai Iske.
  4.  
  5. ;========================================================
  6. ; Set Strings
  7.  
  8. (set #nokick
  9. (cat "You must be using Kickstart 2.04 to use RO. Aborting!"
  10. ))
  11.  
  12. (set #nomui
  13. (cat "You need version 3.3 of MUI or better. Aborting!"
  14. ))
  15.  
  16. (set #startmsg
  17. (cat "\n\RO installation script.\n"
  18.      "This script installs RO on your Amiga.\n\n"
  19.      "Read the Documentation files for\n"
  20.      "more information on the distribution.\n"
  21.      "RO © 1994-1996 Oliver Rummeyer\n"
  22.      "All rights reserved."
  23. ))
  24.  
  25. (set #icons "Which type of icons would you like to install")
  26. (set #magicwbicons "MagicWB-Style Icons; 8 colors")
  27. (set #classicicons "Classic-WB-Style Icons; 4 colors")
  28. (set #noicons "No Icons")
  29.  
  30. (set #install "\n\nInstalling RO to\n\n")
  31. (set #drawer
  32. (cat "In which disk or drawer should RO be installed?\n"
  33.      "(A drawer \"RO\" will be created there)"
  34. ))
  35.  
  36. (set #update
  37. (cat "A drawer \"RO\" already exists in the specified disk "
  38.      "or drawer. Your prefs settings are NOT changed if you "
  39.      "continue the installation procedure. Check the documentation "
  40.      "as some additional configuration keywords might be "
  41.      "introduced by this update.\n\n"
  42.      "Should I continue the installation procedure?"
  43. ))
  44.  
  45. (set #lang "Which languages should be installed?")
  46. (set #own
  47. (cat    "\n\nIf you want to create own versions of\n"
  48.     "the catalogs please have a look at the\n"
  49.     "distributions Locale directory. You will\n"
  50.     "find the .ct and .cd files there."
  51. ))
  52.  
  53. (set #install-docs "Would you like to install RO's documentation?")
  54. (set #doc "Which documentation formats would you like to install?")
  55. (set #doclang "Which language do you prefer for the documentation?")
  56.  
  57. (set #install-rexx "Would you like to install the arexx examples?")
  58. (set #drawer-rexx "In which disk or drawer should the arexx examples be installed?")
  59.  
  60. (set #exitmsg
  61. (cat "Please support the shareware concept!\n\n"
  62.      "If you like RO, please send $20.- or DM 30.- to\n\n"
  63.      "Oliver Rummeyer\n"
  64.      "Hochbergstraße 49/1\n"
  65.      "D-88213 Ravensburg\n"
  66.      "Germany/Europe"
  67. ))
  68. ;========================================================
  69.  
  70. (if (< (/ (getversion) 65536) 37)
  71. (
  72.     (abort #nokick)
  73. ))
  74.  
  75. (if (= (exists "LIBS:muimaster.library" (noreq)) 1)
  76. (
  77.     (if (>= (run "c:Version muimaster.library VERSION 14 REVISION 106") 5)
  78.     (
  79.         (abort #nomui)
  80.     ))
  81. )
  82. (
  83.     (abort #nomui)
  84. ))
  85.  
  86. ;=========================================================
  87.  
  88. (message #startmsg)
  89.  
  90. (complete 0)
  91.  
  92. ;=========================================================
  93.  
  94. (set IconType
  95.     (askchoice
  96.         (prompt #icons)
  97.         (help @askchoice-help)
  98.         (choices
  99.             #magicwbicons
  100.             #classicicons
  101.             #noicons
  102.         )
  103.         (default 0)
  104.     )
  105. )
  106.  
  107. (complete 15)
  108.  
  109. ;=========================================================
  110.  
  111. (set TargetDir
  112.     (askdir
  113.         (prompt #drawer)
  114.         (default "SYS:Tools")
  115.         (help @askdir-help)
  116.     )
  117. )
  118.  
  119. (set DestDir (tackon TargetDir "RO"))
  120. (set @default-dest DestDir)
  121.  
  122. (if (= (exists DestDir) 2)
  123.    (message #update)
  124. )
  125.  
  126. (complete 30)
  127.  
  128. ;=========================================================
  129.  
  130. (makedir DestDir
  131.     (prompt #install DestDir)
  132. )
  133.  
  134. (if (= IconType 0)
  135. (
  136.        (copyfiles
  137.            (source "")
  138.         (choices "/Icons/8col/RO.info" "/Icons/8col/ROPrefs.info" "/Icons/8col/RO.guide.info" "/Icons/8col/RegForm.info")
  139.            (dest DestDir)
  140.     )
  141.     (copyfiles
  142.         (source "/Icons/8col/Drawer.info")
  143.         (dest TargetDir)
  144.         (newname "RO.info")
  145.     )
  146. ))
  147.  
  148. (if (= IconType 1)
  149. (
  150.        (copyfiles
  151.            (source "")
  152.         (choices "/Icons/4col/RO.info" "/Icons/4col/ROPrefs.info" "/Icons/4col/RO.guide.info" "/Icons/4col/RegForm.info")
  153.            (dest DestDir)
  154.     )
  155.     (copyfiles
  156.         (source "/Icons/4col/Drawer.info")
  157.         (dest TargetDir)
  158.         (newname "RO.info")
  159.     )
  160. ))
  161.  
  162. (copyfiles
  163.     (help @copyfiles-help)
  164.     (source "/Binary/RO,binary")
  165.     (dest DestDir)
  166.     (newname "RO")
  167. )
  168.  
  169. (copyfiles
  170.     (help @copyfiles-help)
  171.     (source "/Binary/ROPrefs,binary")
  172.     (dest DestDir)
  173.     (newname "ROPrefs")
  174. )
  175.  
  176. (if (= (exists "ENV:RO") 0)
  177.     (makedir "ENV:RO")
  178. )
  179. (if (= (exists "ENVARC:RO") 0)
  180.     (makedir "ENVARC:RO")
  181. )
  182.  
  183. (if (= (exists "ENV:RO/RO.prefs") 0)
  184.     (copyfiles
  185.         (help @copyfiles-help)
  186.         (source "/Config/RO.prefs,default")
  187.         (dest "ENV:RO/")
  188.         (newname "RO.prefs")
  189.     )
  190. )
  191.  
  192. (if (= (exists "ENVARC:RO/RO.prefs") 0)
  193.     (copyfiles
  194.         (help @copyfiles-help)
  195.         (source "/Config/RO.prefs,default")
  196.         (dest "ENVARC:RO/")
  197.         (newname "RO.prefs")
  198.     )
  199. )
  200.  
  201. (complete 45)
  202.  
  203. ;========================================================
  204. ; Install Locale
  205.  
  206. (if (AND (NOT (= (getassign "Locale") "")) (exists "libs:locale.library"))
  207. (
  208.  
  209.     (set Lang
  210.         (askoptions
  211.             (prompt #lang)
  212.             (help @askoptions-help)
  213.             (choices "Deutsch" "Français" "Svenska" )
  214.             (default 0)
  215.         )
  216.     )
  217.  
  218.     (if (IN Lang 0)
  219.         (copyfiles
  220.             (source "")
  221.             (choices "/Locale/Catalogs/Deutsch/ro.catalog")
  222.             (dest "LOCALE:Catalogs/Deutsch")
  223.         )
  224.     )
  225.  
  226.     (if (IN Lang 1)
  227.         (copyfiles
  228.             (source "")
  229.             (choices "/Locale/Catalogs/Français/ro.catalog")
  230.             (dest "LOCALE:Catalogs/Français")
  231.         )
  232.     )
  233.  
  234.     (if (IN Lang 2)
  235.         (copyfiles
  236.             (source "")
  237.             (choices "/Locale/Catalogs/Svenska/ro.catalog")
  238.             (dest "LOCALE:Catalogs/Svenska")
  239.         )
  240.     )
  241.  
  242.     (message #own)
  243. ))
  244.  
  245. (complete 60)
  246.  
  247. ;========================================================
  248. ; Install ARexx Scripts
  249.  
  250. (if (askbool (help @askbool-help) (prompt #install-rexx))
  251. (
  252.     (set RexxDir
  253.     (askdir
  254.         (prompt #drawer-rexx)
  255.         (default "REXX:")
  256.         (help @askdir-help)
  257.     ))
  258.  
  259.        (copyfiles
  260.            (source "")
  261.         (choices
  262.             "/ARexx/Action.RO"
  263.             "/ARexx/AddArc.RO"
  264.             "/ARexx/ArcHandler.RO"
  265.             "/ARexx/Iconify.RO"
  266.             "/ARexx/LoadDir.RO"
  267.             "/ARexx/LoadOther.RO"
  268.             "/ARexx/PlayModule.RO"
  269.         )
  270.            (dest RexxDir)
  271.     )
  272.  
  273. ))
  274.  
  275. (complete 75)
  276.  
  277. ;=========================================================
  278. ; Install Documentation
  279.  
  280. (if (askbool (help @askbool-help) (prompt #install-docs))
  281. (
  282.  
  283.     (set doctype
  284.         (askoptions
  285.             (prompt #doc)
  286.             (help @askoptions-help)
  287.             (choices
  288.                 "AmigaGuide ® V39"
  289.             )
  290.             (default 1)
  291.         )
  292.     )
  293.  
  294.     (if (<> doctype 0)
  295.     (
  296.  
  297.         (set doclang
  298.             (askchoice
  299.                 (prompt #doclang)
  300.                 (help @askchoice-help)
  301.                 (choices
  302.                     "English"
  303.                     "Deutsch"
  304.                     "Français"
  305.                     "Svenska"
  306.                 )
  307.                 (default 0)
  308.             )
  309.         )
  310.     ))
  311.  
  312.     (if (= doctype 1)
  313.     (
  314.  
  315.         (if (= doclang 0)
  316.         (
  317.             (copyfiles
  318.                 (source "/Docs/RO.guide,english")
  319.                 (dest DestDir)
  320.                 (newname "RO.guide")
  321.             )
  322.             (copyfiles
  323.                 (source "/Docs/RegForm,english")
  324.                 (dest DestDir)
  325.                 (newname "RegForm")
  326.             )
  327.         ))
  328.  
  329.         (if (= doclang 1)
  330.         (
  331.             (copyfiles
  332.                 (source "/Docs/RO.guide,deutsch")
  333.                 (dest DestDir)
  334.                 (newname "RO.guide")
  335.             )
  336.             (copyfiles
  337.                 (source "/Docs/RegForm,deutsch")
  338.                 (dest DestDir)
  339.                 (newname "RegForm")
  340.             )
  341.         ))
  342.  
  343.         (if (= doclang 2)
  344.         (
  345.             (copyfiles
  346.                 (source "/Docs/RO.guide,francais")
  347.                 (dest DestDir)
  348.                 (newname "RO.guide")
  349.             )
  350.             (copyfiles
  351.                 (source "/Docs/RegForm,francais")
  352.                 (dest DestDir)
  353.                 (newname "RegForm")
  354.             )
  355.         ))
  356.  
  357.         (if (= doclang 3)
  358.         (
  359.             (copyfiles
  360.                 (source "/Docs/RO.guide,svenska")
  361.                 (dest DestDir)
  362.                 (newname "RO.guide")
  363.             )
  364.             (copyfiles
  365.                 (source "/Docs/RegForm,svenska")
  366.                 (dest DestDir)
  367.                 (newname "RegForm")
  368.             )
  369.         ))
  370.  
  371.     ))
  372.  
  373.     (if (= doctype 0)
  374.     (
  375.         (delete    (tackon DestDir "RO.guide.info"))
  376.         (delete    (tackon DestDir "RegForm.info"))
  377.     ))
  378.  
  379. )
  380. (
  381.     (delete    (tackon DestDir "RO.guide.info"))
  382.     (delete    (tackon DestDir "RegForm.info"))
  383. ))
  384.  
  385. (complete 100)
  386.  
  387. ;==========================================================
  388. (exit #exitmsg)
  389.